package com.apes.fico.finance.model.statements;

import com.apes.framework.jpa.DefaultPersistListener;
import com.apes.framework.jpa.comment.Comment;
import com.apes.framework.jpa.generator.ApesGenerator;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.SelectBeforeUpdate;

import javax.persistence.*;

/**
 * @program: apestech
 * @description: 利润表
 * @author: Chengxm
 * @create: 2019-01-23 10:28
 **/
@Getter
@Setter
@SelectBeforeUpdate
@DynamicInsert
@DynamicUpdate
@Entity
@EntityListeners(DefaultPersistListener.class)
@Table(name = IncomeStatement.CONST_TABLE_NAME)
public class IncomeStatement {
    public final static String CONST_TABLE_NAME = "gl_income_statement";
    @Id
    @Column(name = "id", nullable = false, length = 32)
    @ApesGenerator(code = CONST_TABLE_NAME, name = "利润表模板", padding = 8)
    @Comment("编号")
    private String id;

    @Column(name ="project",length = 400)
    @Comment("项目")
    private  String  project;

    @Column(name = "instant_equation")
    @Comment("本月公式")
    private String instantEquation;

    @Column(name="current_year_equation")
    @Comment("本年公式")
    private String currentYearEquation;
}
